package com.lpwa.framework.netty.utils;

import com.lpwa.common.utils.StaticRedisUtil;
import com.lpwa.system.mapper.TagLocatorMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;
import javax.xml.crypto.Data;
import java.util.Date;

/**
 * @Description 静态方法中调用非静态方法
 * @Author qizhentao
 * @Date 2020/7/1 11:27
 * @Version 1.0
 */
@Component
public class StaticTagLocatorMapper {
    @Autowired
    private TagLocatorMapper tagLocatorMapper;
 
    public static TagLocatorMapper staticTagLocatorMapper;
    // 项目启动时把redisUtil交给静态的staticRedisUtil
    @PostConstruct
    public void init() {
        staticTagLocatorMapper = this.tagLocatorMapper;
    }
}